<template>
  <div class="likeMusic">
    <!-- 歌单信息组件 -->
    <!-- <songListDetails></songListDetails> -->
    <!-- 歌曲列表标题栏 -->
    <songListRow></songListRow>
    <!-- 单条歌曲组件 -->
    <el-empty 
    v-if="likeMusic.length==0"
    :image="`${url}/images/empty.png`"
    :description="`真 的 一 首 都 没 有 嘛……`"
    ></el-empty>
    <songline :col="index" :music="item"  v-for="(item,index) of likeMusic" :key="index" :index="index"></songline>
  </div>
</template>

<script>
import {url} from "@/apiUrl"//引入地址
import songListDetails from '@/components/songListDetails.vue';
import songline from "../../components/songline.vue"
import songListRow from '@/components/songListRow.vue'
import { mapState } from 'vuex'
export default {
    components:{
      songListDetails,
      songline,
      songListRow
    },
    computed:{
      ...mapState({
        likeMusic:state=>state.likeMusic
      })
    },
    data(){
      return {
        url:null
      }
    },
   created(){
    this.$store.commit("getLikeMusic",[()=>{}])
    },
    mounted(){
      this.url=url
    }
  
}
</script>

<style lang="scss" scoped>
</style>